package com.tengjunjie.qianqianaccountbook.qianqianaccountbook.exception;


import com.tengjunjie.qianqianaccountbook.qianqianaccountbook.enums.ResultEnum;

/**
 * Created by tengjunjie
 * 2017-12-03 18:55
 */
public class AccountBookException extends RuntimeException{

    private Integer code;

    public AccountBookException(ResultEnum resultEnum) {
        super(resultEnum.getMessage());

        this.code = resultEnum.getCode();
    }

    public AccountBookException(Integer code, String message) {
        super(message);
        this.code = code;
    }
}
